;;====================================START OF PERSONALITY=================================

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;PERSONALITY;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;control variable for personality: begin_psnlt
;;add (assert (begin_psnlt)) to start PERSONALITY part

;=============================FILTER AND INITIALIZE CURRENT GOAL===========================================
;;;;added by ruitao;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;; decrease facts by deleting same gender;;;;;;;;
(defrule decrease_psnlt_facts
	(declare (salience 4))
	(target_gender f)
	?f1 <- (fact_personality (name ?name) (gender m) (job ?job) (cf-ei ?ei) (cf-sn ?sn) (cf-tf ?tf) (cf-jp ?jp))
=>
	(retract ?f1)
)

(defrule decrease_psnlt_facts2
	(declare (salience 4))
	(target_gender m)
	?f1 <- (fact_personality (name ?name) (gender f) (job ?job) (cf-ei ?ei) (cf-sn ?sn) (cf-tf ?tf) (cf-jp ?jp))
=>
	(retract ?f1)
)	
	
;;;;;;;;;;;;;;;;;;;END OF FACTS;;;;;;;;;;;;;;;;;;;;;;;;;
;;initial current_goal
(defrule initiate_current_goal
	(declare (salience -7)) 
    (begin_psnlt)    
    (fact_personality (name you) (cf-ei ?cf-ei) (cf-sn ?cf-sn) (cf-tf ?cf-tf) (cf-jp ?cf-jp))
=>    (assert (current_goal (category psnlt-ei) (name you) (cf ?cf-ei)))
    (assert (current_goal (category psnlt-sn) (name you) (cf ?cf-sn)))
    (assert (current_goal (category psnlt-tf) (name you) (cf ?cf-tf)))
    (assert (current_goal (category psnlt-jp) (name you) (cf ?cf-jp)))
    (assert (begin_question_psnlt))    ;start question part
)

;;===========================================START OF QUESTION PARTS================================================
;;Extraversion - Intraversion
(defrule ei-q1
    (logical (begin_question_psnlt))
=>
        (assert (UI-state (display ei-q1)
                     (relation-asserted ei_answer_q1)
                     (response ei-q1-1)    
                     (valid-answers ei-q1-1 ei-q1-2))))

(defrule convert-ei-q1
    (logical (ei_answer_q1 ?a))
=>
    (switch ?a 
        (case ei-q1-1 then (assert (working_goal (category psnlt-ei) (name you) (cf -0.8)))) 
        (case ei-q1-2 then (assert (working_goal (category psnlt-ei) (name you) (cf 0.8))))
    ))

(defrule ei-q2
    (logical (ei_answer_q1 ?a))
=>
        (assert (UI-state (display ei-q2)
                     (relation-asserted ei_answer_q2)
                     (response ei-q2-1)    
                     (valid-answers ei-q2-1 ei-q2-2))))

(defrule convert-ei-q2
    (logical (ei_answer_q2 ?a))
=>
    (switch ?a 
        (case ei-q2-1 then (assert (working_goal (category psnlt-ei) (name you) (cf -0.8)))) 
        (case ei-q2-2 then (assert (working_goal (category psnlt-ei) (name you) (cf 0.8))))
    ))

(defrule ei-q3
    (declare (salience 3))
    (logical (ei_answer_q2 ?a))
    (logical (current_goal (category psnlt-ei) (name you) (cf 0.0)))    ;;ask question 3 only if the answers from 1 and 2 are conflicteed    
=>
        (assert (UI-state (display ei-q3)
                     (relation-asserted ei_answer_q3)
                     (response ei-q3-1)    
                     (valid-answers ei-q3-1 ei-q3-2))))

(defrule convert-ei-q3
    (logical (ei_answer_q3 ?a))
=>
    (switch ?a 
        (case ei-q3-1 then (assert (working_goal (category psnlt-ei) (name you) (cf -0.8)))) 
        (case ei-q3-2 then (assert (working_goal (category psnlt-ei) (name you) (cf 0.8))))
    ))

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;Sensing - iNtuition
(defrule sn-q1
    (logical (ei_answer_q2 ?a))
=>
        (assert (UI-state (display sn-q1)
                     (relation-asserted sn_answer_q1)
                     (response sn-q1-1)    
                     (valid-answers sn-q1-1 sn-q1-2))))

(defrule convert-sn-q1
    (logical (sn_answer_q1 ?a))
=>
    (switch ?a 
        (case sn-q1-1 then (assert (working_goal (category psnlt-sn) (name you) (cf -0.8)))) 
        (case sn-q1-2 then (assert (working_goal (category psnlt-sn) (name you) (cf 0.8))))
    ))

(defrule sn-q2
    (logical (sn_answer_q1 ?a))
=>
        (assert (UI-state (display sn-q2)
                     (relation-asserted sn_answer_q2)
                     (response sn-q2-1)    
                     (valid-answers sn-q2-1 sn-q2-2))))

(defrule convert-sn-q2
    (logical (sn_answer_q2 ?a))
=>
    (switch ?a 
        (case sn-q2-1 then (assert (working_goal (category psnlt-sn) (name you) (cf -0.8)))) 
        (case sn-q2-2 then (assert (working_goal (category psnlt-sn) (name you) (cf 0.8))))
    ))

(defrule sn-q3
    (declare (salience 3))
    (logical (sn_answer_q2 ?a))
    (logical (current_goal (category psnlt-sn) (name you) (cf 0.0)))    ;;ask question 3 only if the answers from 1 and 2 are conflicteed    
=>
        (assert (UI-state (display sn-q3)
                     (relation-asserted sn_answer_q3)
                     (response sn-q3-1)    
                     (valid-answers sn-q3-1 sn-q3-2))))

(defrule convert-sn-q3
    (logical (sn_answer_q3 ?a))
=>
    (switch ?a 
        (case sn-q3-1 then (assert (working_goal (category psnlt-sn) (name you) (cf -0.8)))) 
        (case sn-q3-2 then (assert (working_goal (category psnlt-sn) (name you) (cf 0.8))))
    ))

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;Thinking - Feeling
(defrule tf-q1
    (logical (sn_answer_q2 ?a))
=>
        (assert (UI-state (display tf-q1)
                     (relation-asserted tf_answer_q1)
                     (response tf-q1-1)    
                     (valid-answers tf-q1-1 tf-q1-2))))

(defrule convert-tf-q1
    (logical (tf_answer_q1 ?a))
=>
    (switch ?a 
        (case tf-q1-1 then (assert (working_goal (category psnlt-tf) (name you) (cf -0.8)))) 
        (case tf-q1-2 then (assert (working_goal (category psnlt-tf) (name you) (cf 0.8))))
    ))

(defrule tf-q2
    (logical (tf_answer_q1 ?a))
=>
        (assert (UI-state (display tf-q2)
                     (relation-asserted tf_answer_q2)
                     (response tf-q2-1)    
                     (valid-answers tf-q2-1 tf-q2-2))))

(defrule convert-tf-q2
    (logical (tf_answer_q2 ?a))
=>
    (switch ?a 
        (case tf-q2-1 then (assert (working_goal (category psnlt-tf) (name you) (cf -0.8)))) 
        (case tf-q2-2 then (assert (working_goal (category psnlt-tf) (name you) (cf 0.8))))
    ))

(defrule tf-q3
    (declare (salience 3))
    (logical (tf_answer_q2 ?a))
    (logical (current_goal (category psnlt-tf) (name you) (cf 0.0)))    ;;ask question 3 only if the answers from 1 and 2 are conflicteed    
=>
        (assert (UI-state (display tf-q3)
                     (relation-asserted tf_answer_q3)
                     (response tf-q3-1)    
                     (valid-answers tf-q3-1 tf-q3-2))))

(defrule convert-tf-q3
    (logical (tf_answer_q3 ?a))
=>
    (switch ?a 
        (case tf-q3-1 then (assert (working_goal (category psnlt-tf) (name you) (cf -0.8)))) 
        (case tf-q3-2 then (assert (working_goal (category psnlt-tf) (name you) (cf 0.8))))
    ))

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;Judging - Perceiving
(defrule jp-q1
    (logical (sn_answer_q2 ?a))
=>
        (assert (UI-state (display jp-q1)
                     (relation-asserted jp_answer_q1)
                     (response jp-q1-1)    
                     (valid-answers jp-q1-1 jp-q1-2))))

(defrule convert-jp-q1
    (logical (jp_answer_q1 ?a))
=>
    (switch ?a 
        (case jp-q1-1 then (assert (working_goal (category psnlt-jp) (name you) (cf -0.8)))) 
        (case jp-q1-2 then (assert (working_goal (category psnlt-jp) (name you) (cf 0.8))))
    ))

(defrule jp-q2
    (logical (jp_answer_q1 ?a))
=>
        (assert (UI-state (display jp-q2)
                     (relation-asserted jp_answer_q2)
                     (response jp-q2-1)    
                     (valid-answers jp-q2-1 jp-q2-2))))

(defrule convert-jp-q2
    (logical (jp_answer_q2 ?a))
=>
    (switch ?a 
        (case jp-q2-1 then (assert (working_goal (category psnlt-jp) (name you) (cf -0.8)))) 
        (case jp-q2-2 then (assert (working_goal (category psnlt-jp) (name you) (cf 0.8))))
    ))

(defrule jp-q3
    (declare (salience 3))
    (logical (current_goal (category psnlt-jp) (name you) (cf 0.0)))    ;;ask question 3 only if the answers from 1 and 2 are conflicteed    
=>
        (assert (UI-state (display jp-q3)
                     (relation-asserted jp_answer_q3)
                     (response jp-q3-1)    
                     (valid-answers jp-q3-1 jp-q3-2))))

(defrule convert-jp-q3
    (logical (jp_answer_q3 ?a))
=>
    (switch ?a 
        (case jp-q3-1 then (assert (working_goal (category psnlt-jp) (name you) (cf -0.8)))) 
        (case jp-q3-2 then (assert (working_goal (category psnlt-jp) (name you) (cf 0.8))))
    ))

;;====================================================END OF QUESTION PART==========================================




;;finish questionnaire part, start matching process
(defrule update_fact
    (declare (salience -10))
    (logical (jp_answer_q2 ?a))
    (not (update_fact executed))   ;only run once
    ?f1 <- (current_goal (category psnlt-ei) (name you) (cf ?cf-ei))
    ?f2 <- (current_goal (category psnlt-sn) (name you) (cf ?cf-sn))
    ?f3 <- (current_goal (category psnlt-tf) (name you) (cf ?cf-tf))
    ?f4 <- (current_goal (category psnlt-jp) (name you) (cf ?cf-jp))
    ?f <- (fact_personality (name you) (cf-ei ?cf-ei-you) (cf-sn ?cf-sn-you) (cf-tf ?cf-tf-you) (cf-jp ?cf-jp-you))
=>  (modify ?f (cf-ei ?cf-ei) (cf-sn ?cf-sn) (cf-tf ?cf-tf) (cf-jp ?cf-jp))
    ;(retract ?f1)  
    ;(retract ?f2)
    ;(retract ?f3)
    ;(retract ?f4)
    (assert (begin_match))
    (assert (update_fact executed))
)


;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;ROUND TO UNIT CF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;round to -1 and 1 for match rule
(defrule round_ngt_ei
    (begin_match)
    ?f <- (fact_personality (name ?name) (cf-ei ?cf-ei) (cf-sn ?cf-sn) (cf-tf ?cf-tf) (cf-jp ?cf-jp))
    (test (and (< ?cf-ei 0) (> ?cf-ei -1)))
=>    (modify ?f (cf-ei -1)) 
)
(defrule round_ngt_sn
    (begin_match)
    ?f <- (fact_personality (name ?name) (cf-ei ?cf-ei) (cf-sn ?cf-sn) (cf-tf ?cf-tf) (cf-jp ?cf-jp))
    (test (and (< ?cf-sn 0) (> ?cf-sn -1)))
=>    (modify ?f (cf-sn -1)) 
)
(defrule round_ngt_tf
    (begin_match)
    ?f <- (fact_personality (name ?name) (cf-ei ?cf-ei) (cf-sn ?cf-sn) (cf-tf ?cf-tf) (cf-jp ?cf-jp))
    (test (and (< ?cf-tf 0) (> ?cf-tf -1)))
=>    (modify ?f (cf-tf -1)) 
)
(defrule round_ngt_jp
    (begin_match)
    ?f <- (fact_personality (name ?name) (cf-ei ?cf-ei) (cf-sn ?cf-sn) (cf-tf ?cf-tf) (cf-jp ?cf-jp))
    (test (and (< ?cf-jp 0) (> ?cf-jp -1)))
=>    (modify ?f (cf-jp -1)) 
)

(defrule round_pst_ei
    (begin_match)
    ?f <- (fact_personality (name ?name) (cf-ei ?cf-ei) (cf-sn ?cf-sn) (cf-tf ?cf-tf) (cf-jp ?cf-jp))
    (test (and (> ?cf-ei 0) (< ?cf-ei 1)))
=>    (modify ?f (cf-ei 1)) 
)
(defrule round_pst_sn
    (begin_match)
    ?f <- (fact_personality (name ?name) (cf-ei ?cf-ei) (cf-sn ?cf-sn) (cf-tf ?cf-tf) (cf-jp ?cf-jp))
    (test (and (> ?cf-sn 0) (< ?cf-sn 1)))
=>    (modify ?f (cf-sn 1)) 
)
(defrule round_pst_tf
    (begin_match)
    ?f <- (fact_personality (name ?name) (cf-ei ?cf-ei) (cf-sn ?cf-sn) (cf-tf ?cf-tf) (cf-jp ?cf-jp))
    (test (and (> ?cf-tf 0) (< ?cf-tf 1)))
=>    (modify ?f (cf-tf 1)) 
)
(defrule round_pst_jp
    (begin_match)
    ?f <- (fact_personality (name ?name) (cf-ei ?cf-ei) (cf-sn ?cf-sn) (cf-tf ?cf-tf) (cf-jp ?cf-jp))
    (test (and (> ?cf-jp 0) (< ?cf-jp 1)))
=>    (modify ?f (cf-jp 1)) 
)


(defrule initiate_psnlt_current_goal
    (declare (salience 5))
    (begin_match)
    (fact_personality (name ?name))
    (test (neq ?name you))
=>   (assert (current_goal (category psnlt) (name ?name)  (cf 0)))
)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;KEIRSEY'S RULE TO MATCH PEOPLE
;;Opposites attract but the perceiving function (that's S or N) must be the same.

(defrule keirsey_rule
    ;(printout t "Inside Keirsey_rule" crlf)
    (declare (salience 3))    
    (begin_match)
    (fact_personality (name ?name) (cf-ei ?cf-ei) (cf-sn ?cf-sn) (cf-tf ?cf-tf) (cf-jp ?cf-jp))
    (fact_personality (name you) (cf-ei ?cf-ei-you) (cf-sn ?cf-sn-you) (cf-tf ?cf-tf-you) (cf-jp ?cf-jp-you))
    (test (neq ?name you))
    (not (stop_match ?name))    ;already applied keirsey or cj rule
    (not (stop_match_snei ?name))    ;already applied sn or ei rule
    (test (= 1 (* ?cf-sn ?cf-sn-you)))
    (test (= -1 (* ?cf-ei ?cf-ei-you)))
    (test (= -1 (* ?cf-tf ?cf-tf-you)))
    (test (= -1 (* ?cf-jp ?cf-jp-you)))
=>    (assert (working_goal (category psnlt) (name ?name) (cf 0.7)))
       (assert (stop_match ?name))    ;;indicate keirsey rule is already applied for ?name
    (assert (reason (name ?name) (category personality) (subcategory "Keirsey rule")(reasondesc "You and your match have same Sensing/Intuition function (see thing in the same way) and opposite Extraversion/Intraversion, Thinking/Feeling and Judging/Perceiving function (which attracts each other)")))
)

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;CARL JUNG'S RULE TO MATCH PEOPLE (personalitypage.com)
;;Extrovert and Introvert attract each other
;;Judging and Perceiving attract each other
;;However they should have similar dominant function
;;ExTJ and IxTP (Dominant Thinking)
;;ExFJ and IxFP (Dominant Feeling)
(defrule cj_dominant_tf
    (declare (salience 3))    
    (begin_match)
    (fact_personality (name ?name) (cf-ei ?cf-ei) (cf-sn ?cf-sn) (cf-tf ?cf-tf) (cf-jp ?cf-jp))
    (fact_personality (name you) (cf-ei ?cf-ei-you) (cf-sn ?cf-sn-you) (cf-tf ?cf-tf-you) (cf-jp ?cf-jp-you))
    (not (stop_match ?name))    ;already applied keirsey or cj rule
    (not (stop_match_snei ?name))    ;already applied sn or ei rule
    (test (neq ?name you))
    (test (= -1 (* ?cf-ei ?cf-ei-you)))    ;E goes with I
    (test (= -1 (* ?cf-jp ?cf-jp-you)))    ;J goes with P
    (test (= 1 (* ?cf-ei ?cf-jp)))         ;EJ or IP
    (test (= 1 (* ?cf-ei-you ?cf-jp-you))) ;EJ or IP
    (test (= 1 (* ?cf-tf ?cf-tf-you)))     ;T goes with T or F goes with F
    ;ignore SN
=>    (assert (working_goal (category psnlt) (name ?name) (cf 0.7)))
    (assert (stop_match ?name))    ;;indicate Carl Jung rule is already applied for ?name
    (assert (reason (name ?name) (category personality) (subcategory "Carl Jung's rule")(reasondesc "You and your match have same Thinking/Feeling function (see thing in the same way) and opposite Extraversion/Intraversion and Judging/Perceiving function (which attracts each other)")))
)
;;ENxP and INxJ (Dominant Intuition)
;;ESxP and ISxJ (Dominant Sensing)
(defrule cj_dominant_sn
    (declare (salience 3))    
    (begin_match)
    (fact_personality (name ?name) (cf-ei ?cf-ei) (cf-sn ?cf-sn) (cf-tf ?cf-tf) (cf-jp ?cf-jp))
    (fact_personality (name you) (cf-ei ?cf-ei-you) (cf-sn ?cf-sn-you) (cf-tf ?cf-tf-you) (cf-jp ?cf-jp-you))
    (not (stop_match ?name))    ;already applied keirsey or cj rule
    (not (stop_match_snei ?name))    ;already applied sn or ei rule
    (test (neq ?name you))
    (test (= -1 (* ?cf-ei ?cf-ei-you)))    ;E goes with I
    (test (= -1 (* ?cf-jp ?cf-jp-you)))    ;J goes with P
    (test (= -1 (* ?cf-ei ?cf-jp)))         ;EP or IJ
    (test (= -1 (* ?cf-ei-you ?cf-jp-you))) ;EP or IJ
    (test (= 1 (* ?cf-sn ?cf-sn-you)))     ;S goes with S or N goes with N
    ;ignore TF
=>    (assert (working_goal (category psnlt) (name ?name) (cf 0.7)))
    (assert (stop_match ?name))
    (assert (reason (name ?name) (category personality) (subcategory "Carl Jung's rule")(reasondesc "You and your match have same Sensing/Intuition function (see thing in the same way) and opposite Extraversion/Intraversion and Judging/Perceiving function (which attracts each other)")))
)

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;;;;Rule SN:As far as long-term potential goes, the most important aspect of a relationship is simply that 
;;;both members of the couple are seeing things the same way or coming from the same place. 
;;;When translated into MBTI language that means that S or N should be the same both members of the couple.
(defrule SN_rule
    (declare (salience 1)) 
    (begin_match)    
    (fact_personality (name ?name) (cf-ei ?cf-ei) (cf-sn ?cf-sn) (cf-tf ?cf-tf) (cf-jp ?cf-jp))
    (not (stop_match ?name))    ;already applied keirsey or cj rule
    (fact_personality (name you) (cf-ei ?cf-ei-you) (cf-sn ?cf-sn-you) (cf-tf ?cf-tf-you) (cf-jp ?cf-jp-you))
    (test (neq ?name you))
    (test (= 1 (* ?cf-sn ?cf-sn-you)))    ;having the same sign for SN
=>    (assert (working_goal (category psnlt) (name ?name) (cf 0.4)))
    (assert (stop_match_snei ?name))
    (assert (reason (name ?name) (category personality) (subcategory "Sensing/Intuition rule")(reasondesc "You and your match have same Sensing/Intuition function (see thing in the same way)")))
)
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; there exists a natural attraction between Introverts and Extroverts and that 
;;the day-to-day dynamics of any relationship are at their best when the relationship features this Introvert-Extrovert split
(defrule EI_rule
    (declare (salience 1)) 
    (begin_match)    
    (fact_personality (name ?name) (cf-ei ?cf-ei) (cf-sn ?cf-sn) (cf-tf ?cf-tf) (cf-jp ?cf-jp))
    (not (stop_match ?name))     ;already applied keirsey or cj rule
    (fact_personality (name you) (cf-ei ?cf-ei-you) (cf-sn ?cf-sn-you) (cf-tf ?cf-tf-you) (cf-jp ?cf-jp-you))
    (test (neq ?name you))
    (test (= -1 (* ?cf-ei ?cf-ei-you)))    ;having the different sign for EI
=>    (assert (working_goal (category psnlt) (name ?name) (cf 0.2)))
    (assert (stop_match_snei ?name))
    (assert (reason (name ?name) (category personality) (subcategory "Extraversion/Intraversion rule")(reasondesc "You and your match have opposite Extraversion/Intraversion (which attracts each other)")))
)



;;;;;;;;;;;;;Transfer the psnly cf to the total 4 category cf facts.
(defrule psnltto4
	;;(declare (salience -9))
	(current_goal (category psnlt) (name ?name1) (cf ?cf))
	?f1 <- (person_CFs (name ?name2&:(eq ?name1 ?name2)) (appearance-cf ?a-cf) (edujob-cf ?e-cf) (character-cf ?c-cf&:(neq ?c-cf ?cf)) (horoscope-cf ?h-cf))
=>
	(assert (person_CFs (name ?name2) (appearance-cf ?a-cf) (edujob-cf ?e-cf) (character-cf ?cf) (horoscope-cf ?h-cf)))
	(retract ?f1)
    (assert (start_horo))
)

;;;;;;;;end of psnlt part;;;;;;;;;;;;;;;;;;

;;====================================END OF PERSONALITY=================================





